from selenium.webdriver.common.by import By
from Base import Base

class Page(Base):
    #1.输入账号
    user_loc=(By.XPATH,'/html/body/div[1]/div/section/section/main/div[1]/div[2]/div[1]/div/input')
    def username(self):
        self.send_keys(self.user_loc,'ltt')
    #2.输入密码
    pwd_loc=(By.XPATH,'/html/body/div[1]/div/section/section/main/div[1]/div[2]/div[2]/div/input')
    def password(self):
        self.send_keys(self.pwd_loc,'123456')
    # 3.点击登录
    login_loc=(By.XPATH,'//*[@id="app"]/div/section/section/main/div[1]/div[2]/button[2]')
    def login(self):
        self.click(self.login_loc)
    # 窗口切换
